<template>
	<view class="cloumCenter ">
		<view class="titleH3 mtb20"> 请选择商户类型，不同类型需要提交不同的资料信息 </view>
		<!-- <shopUserPick @sendClick='sendClick' v-if="merchantType == null" /> -->
		<view v-for="([key,item]) in Object.entries(shopUserForm)" :key="key" class=" mtb20 cardContiner">
			<view class="ps20 " style="gap: 20rpx;">
				<view class="titleH2 fontWeight" style="color: #000;">
					{{item.title}}
				</view>
				<form-component :ref="'formChildren' + key" :options="item.option" />
			</view>
		</view>
	</view>
</template>

<script>
	import shopUserPick from './shopUserPick.vue';
	import FormComponent from '@/components/FormComponent/FormComponent.vue';
	import {
		addShopUser
	} from '@/common/addShopUser.js';
	export default {
		components: {
			shopUserPick,
			FormComponent
		},
		data() {
			return {
				shopUserForm: addShopUser.foundation,
				merchantType: null,
			}
		},
		methods: {
			sendClick(e) {
				console.log(e)
				this.merchantType = e
			}
		},
		mounted() {
			console.log('shopUserForm:', this.shopUserForm);
		}
	}
</script>

<style>
</style>